package db.pojo;

import java.util.*;
import java.text.SimpleDateFormat;
import db.ext.Ea_demo_byjsbExt;
@SuppressWarnings("unchecked")
/**
 * ea_demo_byjsb
 */
public class Ea_demo_byjsb {
	/**
	 * SXH
	 */
	public String sXH;
	/**
	 * DWMC
	 */
	public String dWMC;
	/**
	 * GRBM
	 */
	public String gRBM;
	/**
	 * XM
	 */
	public String xM;
	/**
	 * XB
	 */
	public String xB;
	/**
	 * XNL
	 */
	public int xNL;
	/**
	 * FYZE
	 */
	public double fYZE;
	/**
	 * ZFJE
	 */
	public double zFJE;
	/**
	 * YBBX
	 */
	public double yBBX;
	/**
	 * JSSJ
	 */
	public java.util.Date jSSJ;
	/**
	 * YYMC
	 */
	public String yYMC;
	/**
	 * JBR
	 */
	public String jBR;
	SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
	public static Ea_demo_byjsbExt DB = new Ea_demo_byjsbExt(); 
	
	public Ea_demo_byjsb() {
		super();
	}
	
	public Ea_demo_byjsb(String sXH, String dWMC, String gRBM, String xM, String xB, int xNL, double fYZE, double zFJE, double yBBX, java.util.Date jSSJ, String yYMC, String jBR) {
		super();
		this.sXH = sXH; 
		this.dWMC = dWMC; 
		this.gRBM = gRBM; 
		this.xM = xM; 
		this.xB = xB; 
		this.xNL = xNL; 
		this.fYZE = fYZE; 
		this.zFJE = zFJE; 
		this.yBBX = yBBX; 
		this.jSSJ = jSSJ; 
		this.yYMC = yYMC; 
		this.jBR = jBR; 
	}
	
	public String getSXH() {
		return sXH;
	}

	public void setSXH(String sXH) {
		this.sXH = sXH;
	} 
	
	public String getDWMC() {
		return dWMC;
	}

	public void setDWMC(String dWMC) {
		this.dWMC = dWMC;
	} 
	
	public String getGRBM() {
		return gRBM;
	}

	public void setGRBM(String gRBM) {
		this.gRBM = gRBM;
	} 
	
	public String getXM() {
		return xM;
	}

	public void setXM(String xM) {
		this.xM = xM;
	} 
	
	public String getXB() {
		return xB;
	}

	public void setXB(String xB) {
		this.xB = xB;
	} 
	
	public int getXNL() {
		return xNL;
	}

	public void setXNL(int xNL) {
		this.xNL = xNL;
	} 
	
	public void changeXNLWith(int xNL){
		this.xNL += xNL;
	}
	
	public void changeXNLWithMin(int xNL,int min){
		this.xNL += xNL;
		this.xNL = this.xNL < min ? min : this.xNL;
	}
	
	public void changeXNLWithMax(int xNL,int max){
		this.xNL += xNL;
		this.xNL = this.xNL > max ? max : this.xNL;
	}
	
	public void changeXNLWithMaxMin(int xNL,int max,int min){
		this.xNL += xNL;
		this.xNL = this.xNL < min ? min : this.xNL;
		this.xNL = this.xNL > max ? max : this.xNL;
	}	
	public double getFYZE() {
		return fYZE;
	}

	public void setFYZE(double fYZE) {
		this.fYZE = fYZE;
	} 
	
	public void changeFYZEWith(double fYZE){
		this.fYZE += fYZE;
	}
	
	public void changeFYZEWithMin(double fYZE,double min){
		this.fYZE += fYZE;
		this.fYZE = this.fYZE < min ? min : this.fYZE;
	}
	
	public void changeFYZEWithMax(double fYZE,double max){
		this.fYZE += fYZE;
		this.fYZE = this.fYZE > max ? max : this.fYZE;
	}
	
	public void changeFYZEWithMaxMin(double fYZE,double max,double min){
		this.fYZE += fYZE;
		this.fYZE = this.fYZE < min ? min : this.fYZE;
		this.fYZE = this.fYZE > max ? max : this.fYZE;
	}	
	public double getZFJE() {
		return zFJE;
	}

	public void setZFJE(double zFJE) {
		this.zFJE = zFJE;
	} 
	
	public void changeZFJEWith(double zFJE){
		this.zFJE += zFJE;
	}
	
	public void changeZFJEWithMin(double zFJE,double min){
		this.zFJE += zFJE;
		this.zFJE = this.zFJE < min ? min : this.zFJE;
	}
	
	public void changeZFJEWithMax(double zFJE,double max){
		this.zFJE += zFJE;
		this.zFJE = this.zFJE > max ? max : this.zFJE;
	}
	
	public void changeZFJEWithMaxMin(double zFJE,double max,double min){
		this.zFJE += zFJE;
		this.zFJE = this.zFJE < min ? min : this.zFJE;
		this.zFJE = this.zFJE > max ? max : this.zFJE;
	}	
	public double getYBBX() {
		return yBBX;
	}

	public void setYBBX(double yBBX) {
		this.yBBX = yBBX;
	} 
	
	public void changeYBBXWith(double yBBX){
		this.yBBX += yBBX;
	}
	
	public void changeYBBXWithMin(double yBBX,double min){
		this.yBBX += yBBX;
		this.yBBX = this.yBBX < min ? min : this.yBBX;
	}
	
	public void changeYBBXWithMax(double yBBX,double max){
		this.yBBX += yBBX;
		this.yBBX = this.yBBX > max ? max : this.yBBX;
	}
	
	public void changeYBBXWithMaxMin(double yBBX,double max,double min){
		this.yBBX += yBBX;
		this.yBBX = this.yBBX < min ? min : this.yBBX;
		this.yBBX = this.yBBX > max ? max : this.yBBX;
	}	
	public java.util.Date getJSSJ() {
		return jSSJ;
	}

	public void setJSSJ(java.util.Date jSSJ) {
		this.jSSJ = jSSJ;
	} 
	
	public String getYYMC() {
		return yYMC;
	}

	public void setYYMC(String yYMC) {
		this.yYMC = yYMC;
	} 
	
	public String getJBR() {
		return jBR;
	}

	public void setJBR(String jBR) {
		this.jBR = jBR;
	} 
	
	
	public Map ea_demo_byjsbToMap() {
		Map map = new HashMap();
		try {
			map.put("sXH",this.sXH);
			map.put("dWMC",this.dWMC);
			map.put("gRBM",this.gRBM);
			map.put("xM",this.xM);
			map.put("xB",this.xB);
			map.put("xNL",this.xNL);
			map.put("fYZE",this.fYZE);
			map.put("zFJE",this.zFJE);
			map.put("yBBX",this.yBBX);
			map.put("jSSJ",simpleDateFormat.format(this.jSSJ));
			map.put("yYMC",this.yYMC);
			map.put("jBR",this.jBR);
		} catch (Exception e) {
			e.printStackTrace();
		}
		return map;
	}

	public Ea_demo_byjsb mapToEa_demo_byjsb(Map map){
		try {
			String sXH =  map.get("sXH").toString();
			String dWMC =  map.get("dWMC").toString();
			String gRBM =  map.get("gRBM").toString();
			String xM =  map.get("xM").toString();
			String xB =  map.get("xB").toString();
			int xNL = Integer.parseInt( map.get("xNL").toString());
			double fYZE = Double.parseDouble( map.get("fYZE").toString());
			double zFJE = Double.parseDouble( map.get("zFJE").toString());
			double yBBX = Double.parseDouble( map.get("yBBX").toString());
			java.util.Date jSSJ = simpleDateFormat.parse( map.get("jSSJ").toString());
			String yYMC =  map.get("yYMC").toString();
			String jBR =  map.get("jBR").toString();
			Ea_demo_byjsb ea_demo_byjsb = new Ea_demo_byjsb(sXH, dWMC, gRBM, xM, xB, xNL, fYZE, zFJE, yBBX, jSSJ, yYMC, jBR);
			return ea_demo_byjsb;
		} catch (Exception e) {
			e.printStackTrace();
			return null;
		}
	} 
	
	public String toString(){
		return ea_demo_byjsbToMap().toString();
	}
	
	//方便数据操作	
	public Ea_demo_byjsb insert(){
		return DB.insert(this);
	}
	public Ea_demo_byjsb update(){
		return DB.update(this);
	}
	
	public int delete(){
		return DB.delete(this);
	}
	
}
